package com.java.polymorphism.exer_1;

/**
 * @author luzhikun
 * @date 2020/12/5- 15:40
 */
public class AnimalTest_1 {
    public static void main(String[] args) {
        Animal_1 animal = new CatTest_1();

        CatTest_1 catTest1 = new CatTest_1("白色", 4);
        catTest1.eat();
        catTest1.getCatch();
        DogTest_1 dogTest1 = new DogTest_1();
        dogTest1.color = "黄色";
        dogTest1.leg = 4;
        dogTest1.lookDoor();
        System.out.println("狗的颜色是：" + dogTest1.color + " " + "狗的腿有:" + dogTest1.leg);
        System.out.println("猫的颜色是：" + catTest1.color + " " + "猫的腿有:" + catTest1.leg);
    }
}
